class Student:
    def __init__(self,name,age,sex):
        self.name = name
        self.age = age
        self.sex =sex
        print('对象创建后会执行这个方法')

student1 = Student('小雷',20,'男')
print(student1.name)
print(student1.age)
print(student1.sex)